The parametric continuation monad

نویسنده

  • Paul-André Melliès
چکیده

Every dialogue category comes equipped with a continuation monad defined by applying the negation functor twice. In this paper, we advocate that this double negation monad should be understood as part of a larger parametric monad (or a lax action) with parameter taken in the opposite of the dialogue category. This alternative point of view has one main conceptual benefit: it reveals that the strength of the continuation monad is the fragment of a more fundamental and symmetric structure — provided by a distributivity law between the parametric continuation monad and the canonical action of the dialogue category over itself. The purpose of this work is to describe the formal properties of this parametric continuation monad and of its distributivity law.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Accumulating bindings

We give a Haskell implementation of Filinski’s normalisation by evaluation algorithm for the computational lambda-calculus with sums. Taking advantage of extensions to the GHC compiler, our implementation represents object language types as Haskell types and ensures that type errors are detected statically. Following Filinski, the implementation is parameterised over a residualising monad. The ...

متن کامل

Eilenberg-Moore Monoids and Backtracking Monad Transformers

We develop an algebraic underpinning of backtracking monad transformers in the general setting of monoidal categories. As our main technical device, we introduce Eilenberg–Moore monoids, which combine monoids with algebras for strong monads. We show that Eilenberg–Moore monoids coincide with algebras for the list monad transformer (‘done right’) known from Haskell libraries. From this, we obtai...

متن کامل

Monad Transformers for Backtracking Search

This paper extends Escardó and Oliva’s selection monad to the selection monad transformer, a general monadic framework for expressing backtracking search algorithms in Haskell. The use of the closely related continuation monad transformer for similar purposes is also discussed, including an implementation of a DPLL-like SAT solver with no explicit recursion. Continuing a line of work exploring ...

متن کامل

Kan Extensions for Program Optimisation Or: Art and Dan Explain an Old Trick

Many program optimisations involve transforming a program in direct style to an equivalent program in continuation-passing style. This paper investigates the theoretical underpinnings of this transformation in the categorical setting of monads. We argue that so-called absolute Kan Extensions underlie this program optimisation. It is known that every Kan extension gives rise to a monad, the code...

متن کامل

Backtracking, Interleaving, and Terminating Monad Transformers

We design and implement a library for adding backtracking computations to any Haskell monad. Inspired by logic programming, our library provides, in addition to the operations required by the MonadPlus interface, constructs for fair disjunctions, fair conjunctions, conditionals, pruning, and an expressive top-level interface. Implementing these additional constructs is easy in models of backtra...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • Mathematical Structures in Computer Science

دوره 27  شماره 

صفحات  -

تاریخ انتشار 2017